package client;

import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.net.Socket;
import java.net.UnknownHostException;
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

import client.command.handle.ClientCommandHandler;
import client.command.handle.impl.CommandHandler;
import client.command.praser.impl.CommandPraser;

public class Client {

	static CommandPraser cp=new CommandPraser();
	static CommandHandler ch=new CommandHandler();
	public static void main(String[] args) throws UnknownHostException, IOException {
		// TODO Auto-generated method stub
		
	    final  String localPath="\\client";
	    Scanner sc=new Scanner(System.in);
	    String command=""; //record the client command
//		while(sc.hasNext())
//		{
			 command=sc.nextLine();
			 List<String> cmd=new ArrayList<String>();
			 cmd=cp.command(command);
			 
			 StringBuilder sb=ch.command(cmd);
			 System.out.println(sb);
//		}
		
	}
	

}
